{% extends 'layout.html' %}

{% block css %}
    .form-container {
    text-align: center;
    }

    .navbar-form {
    display: inline-block;
    }

{% endblock %}

{% block content %}
    <div style="text-align: center">
        <form class="navbar-form navbar-left" method="GET" style="display: inline-block; text-align: start">
            {#            <button type="button" class="btn btn-primary btn-lg" data-toggle="modal" name="table_choice" value="product" data-target="#myModal">#}
            {#                商品#}
            {#            </button>#}
            <button type="submit" class="btn btn-primary" name="table_choice" value="product">
                商品
            </button>
            <button type="submit" class="btn btn-primary" name="table_choice" value="sales">
                销售
            </button>
            <button type="submit" class="btn btn-primary" name="table_choice" value="category">
                分类
            </button>
            <button type="submit" class="btn btn-primary" name="table_choice" value="brand">
                品牌
            </button>
            <button type="submit" class="btn btn-primary" name="table_choice" value="customer_review"
            >客户评价表
            </button>


        </form>
        <form method="post" style="display: inline-block; text-align: start">
            {% csrf_token %}
            <div class="form-group">
                {% for data in add_form %}
                    <div class="form-group">
                        {{ data.label }}:<label>{{ data }}</label>
                        {{ data.errors.0 }}
                    </div>
                {% endfor %}
            </div>
            <button type="submit" class="btn btn-default">提交</button>
        </form>
    </div>

    {#    ------------修改--------------#}

    {#        <div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">#}
    {#            <div class="modal-dialog" role="document">#}
    {#                <div class="modal-content">#}
    {#                    <div class="modal-header">#}
    {#                        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span#}
    {#                                aria-hidden="true">&times;</span></button>#}
    {#                        <h4 class="modal-title" id="myModalLabel">添加</h4>#}
    {#                    </div>#}
    {#                    <div class="modal-body">#}
    {#                        <form method="post" style="display: inline-block; text-align: start">#}
    {#                            {% csrf_token %}#}
    {#                            <div class="form-group">#}
    {#                                {% for data in add_form %}#}
    {#                                    <div class="form-group">#}
    {#                                        {{ data.label }}:<label>{{ data }}</label>#}
    {#                                        {{ data.errors.0 }}#}
    {#                                    </div>#}
    {#                                {% endfor %}#}
    {#                            </div>#}
    {#                            <button type="submit" class="btn btn-default">提交</button>#}
    {#                        </form>#}
    {#                    </div>#}
    {#                    <div class="modal-footer">#}
    {#                        <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>#}
    {#                        <button type="button" class="btn btn-primary">保存</button>#}
    {#                    </div>#}
    {#                </div>#}
    {#            </div>#}
    {#        </div>#}
    {#    </div>#}






{% endblock %}